home *** CD-ROM | disk | FTP | other *** search
/ Aminet 4 / Aminet 4 - November 1994.iso / aminet / dev / obero / oberon_lib.lha / oberon-a / source1.lha / source / Amiga / Rexx.mod < prev    next >
Text File  |  1994-08-08  |  22KB  |  489 lines

  1. (**************************************************************************
  2.  
  3.      $RCSfile: Rexx.mod $
  4.   Description: Interface to ARexx
  5.  
  6.    Created by: fjc (Frank Copeland)
  7.     $Revision: 3.2 $
  8.       $Author: fjc $
  9.         $Date: 1994/08/08 01:10:12 $
  10.  
  11.   Includes Release 40.15
  12.  
  13.   (C) Copyright 1987,1988,1989,1990 William S. Hawes
  14.   (C) Copyright 1990-1993 Commodore-Amiga, Inc.
  15.       All Rights Reserved
  16.  
  17.   Oberon-A interface Copyright © 1994, Frank Copeland.
  18.   This file is part of the Oberon-A Interface.
  19.   See Oberon-A.doc for conditions of use and distribution.
  20.  
  21. ***************************************************************************)
  22.  
  23. MODULE Rexx;
  24.  
  25. (*
  26. ** $C- CaseChk       $I- IndexChk  $L+ LongAdr   $N- NilChk
  27. ** $P- PortableCode  $R- RangeChk  $S- StackChk  $T- TypeChk
  28. ** $V- OvflChk       $Z- ZeroVars
  29. *)
  30.  
  31. IMPORT E := Exec, D := Dos, SYS := SYSTEM;
  32.  
  33.  
  34. (*
  35. **      $VER: storage.h 1.4 (8.11.91)
  36. **
  37. **      Header file to define ARexx data structures.
  38. *)
  39.  
  40.  
  41. (* The NexxStr structure is used to maintain the internal strings in REXX.
  42.  * It includes the buffer area for the string and associated attributes.
  43.  * This is actually a variable-length structure; it is allocated for a
  44.  * specific length string, and the length is never modified thereafter
  45.  * (since it's used for recycling).
  46.  *)
  47.  
  48. TYPE
  49.  
  50.   NexxStrPtr * = CPOINTER TO NexxStr;
  51.   NexxStr * = RECORD
  52.     ivalue * : LONGINT;                (* integer value                 *)
  53.     length * : E.UWORD;                (* length in bytes (excl null)   *)
  54.     flags *  : E.BSET;                 (* attribute flags               *)
  55.     hash *   : E.UBYTE;                (* hash code                     *)
  56.     buff *   : ARRAY 8 OF CHAR;        (* buffer area for strings       *)
  57.   END; (* NexxStr *)                   (* size: 16 bytes (minimum)      *)
  58.  
  59. CONST
  60.  
  61.   nxAddLen * = 9;                     (* offset plus null byte *)
  62.  
  63. (* String attribute flag bit definitions                                *)
  64.   nsKeep     * = 0;                 (* permanent string?             *)
  65.   nsString   * = 1;                 (* string form valid?            *)
  66.   nsNotNum   * = 2;                 (* non-numeric?                  *)
  67.   nsNumber   * = 3;                 (* a valid number?               *)
  68.   nsBinary   * = 4;                 (* integer value saved?          *)
  69.   nsFloat    * = 5;                 (* floating point format?        *)
  70.   nsExt      * = 6;                 (* an external string?           *)
  71.   nsSource   * = 7;                 (* part of the program source?   *)
  72.  
  73. (* Combinations of flags                                                *)
  74.   nsIntNum   * = { nsNumber, nsBinary, nsString };
  75.   nsDpNum    * = { nsNumber, nsFloat };
  76.   nsAlpha    * = { nsNotNum, nsString };
  77.   nsOwned    * = { nsSource, nsExt, nsKeep };
  78.   nsKeepStr  * = { nsString, nsSource, nsNotNum };
  79.   nsKeepNum  * = { nsString, nsSource, nsNumber, nsBinary };
  80.  
  81. (* The RexxArg structure is identical to the NexxStr structure, but
  82.  * is allocated from system memory rather than from internal storage.
  83.  * This structure is used for passing arguments to external programs.
  84.  * It is usually passed as an "argstring", a pointer to the string buffer.
  85.  *)
  86.  
  87. TYPE
  88.  
  89.   RexxArgPtr * = CPOINTER TO RexxArg;
  90.   RexxArg * = RECORD
  91.     size *   : LONGINT;                (* total allocated length        *)
  92.     length * : E.UWORD;                (* length of string              *)
  93.     flags *  : E.BSET;                 (* attribute flags               *)
  94.     hash *   : E.UBYTE;                (* hash code                     *)
  95.     buff *   : ARRAY 8 OF CHAR;        (* buffer area                   *)
  96.   END; (* RexxArg *)                   (* size: 16 bytes (minimum)      *)
  97.  
  98. (* The RexxMsg structure is used for all communications with REXX
  99.  * programs.  It is an EXEC message with a parameter block appended.
  100.  *)
  101.  
  102. TYPE
  103.  
  104.   RexxMsgPtr * = CPOINTER TO RexxMsg;
  105.   RexxMsg * = RECORD (E.Message)        (* EXEC message structure        *)
  106.     taskBlock - : E.APTR;               (* global structure (private)    *)
  107.     libBase -   : E.LibraryPtr;         (* library base (private)        *)
  108.     action *    : LONGINT;              (* command (action) code         *)
  109.     result1 *   : E.APTR;               (* primary result (return code)  *)
  110.     result2 *   : E.APTR;               (* secondary result              *)
  111.     args *      : ARRAY 16 OF E.STRPTR; (* argument block (ARG0-ARG15)   *)
  112.     passPort *  : E.MsgPortPtr;         (* forwarding port               *)
  113.     commAddr *  : E.STRPTR;             (* host address (port name)      *)
  114.     fileExt *   : E.STRPTR;             (* file extension                *)
  115.     stdin *     : D.FileHandlePtr;      (* input stream (filehandle)     *)
  116.     stdout *    : D.FileHandlePtr;      (* output stream (filehandle)    *)
  117.     avail *     : LONGINT;              (* future expansion              *)
  118.   END; (* RexxMsg *)                   (* size: 128 bytes               *)
  119.  
  120. CONST
  121.  
  122.   maxRMArg  * = 15;                   (* maximum arguments             *)
  123.  
  124. (* Command (action) codes for message packets                           *)
  125.   comm    * = 01000000H;           (* a command-level invocation    *)
  126.   func    * = 02000000H;           (* a function call               *)
  127.   close   * = 03000000H;           (* close the REXX server *)
  128.   query   * = 04000000H;           (* query for information *)
  129.   addFH   * = 07000000H;           (* add a function host           *)
  130.   addLib  * = 08000000H;           (* add a function library        *)
  131.   remLib  * = 09000000H;           (* remove a function library     *)
  132.   addCon  * = 0A000000H;           (* add/update a ClipList string  *)
  133.   remCon  * = 0B000000H;           (* remove a ClipList string      *)
  134.   tcOpn   * = 0C000000H;           (* open the trace console        *)
  135.   tcCls   * = 0D000000H;           (* close the trace console       *)
  136.  
  137. (* Command modifier flag bits                                           *)
  138.   noIO    * = 00010000H;        (* suppress I/O inheritance?     *)
  139.   result  * = 00020000H;        (* result string expected?       *)
  140.   string  * = 00040000H;        (* program is a "string file"?   *)
  141.   token   * = 00080000H;        (* tokenize the command line?    *)
  142.   nonRet  * = 00100000H;        (* a "no-return" message?        *)
  143.  
  144.   rxCodeMask   * = 0FF000000H;
  145.   rxArgMask    * = 0000000FH;
  146.  
  147. (* The RexxRsrc structure is used to manage global resources.  Each node
  148.  * has a name string created as a RexxArg structure, and the total size
  149.  * of the node is saved in the "rrSize" field.  The REXX systems library
  150.  * provides functions to allocate and release resource nodes.  If special
  151.  * deletion operations are required, an offset and base can be provided in
  152.  * "rrFunc" and "rrBase", respectively.  This "autodelete" function will
  153.  * be called with the base in register A6 and the node in A0.
  154.  *)
  155.  
  156. TYPE
  157.  
  158.   RexxRsrcPtr * = CPOINTER TO RexxRsrc;
  159.   RexxRsrc * = RECORD (E.Node)
  160.     func * : INTEGER;                 (* "auto-delete" offset          *)
  161.     base * : E.APTR;                  (* "auto-delete" base            *)
  162.     size * : LONGINT;                 (* total size of node            *)
  163.     arg1 * : E.APTR;                  (* available ...         *)
  164.     arg2 * : E.APTR;                  (* available ...         *)
  165.   END; (* RexxRsrc *)                 (* size: 32 bytes                *)
  166.  
  167. CONST
  168.  
  169. (* Resource node types                                                  *)
  170.   rrtAny      * = 0;                 (* any node type ...             *)
  171.   rrtLib      * = 1;                 (* a function library            *)
  172.   rrtPort     * = 2;                 (* a public port         *)
  173.   rrtFile     * = 3;                 (* a file IoBuff         *)
  174.   rrtHost     * = 4;                 (* a function host               *)
  175.   rrtClip     * = 5;                 (* a Clip List node              *)
  176.  
  177. (* The RexxTask structure holds the fields used by REXX to communicate with
  178.  * external processes, including the client task.  It includes the global
  179.  * data structure (and the base environment).  The structure is passed to
  180.  * the newly-created task in its "wake-up" message.
  181.  *)
  182.  
  183. CONST
  184.  
  185.   globalSz  * = 200;                  (* total size of GlobalData      *)
  186.  
  187. TYPE
  188.  
  189.   RexxTaskPtr * = CPOINTER TO RexxTask;
  190.   RexxTask * = RECORD
  191.     global *   : ARRAY globalSz OF SHORTINT;   (* global data structure *)
  192.     msgPort *  : E.MsgPort;            (* global message port           *)
  193.     flags *    : E.BSET;               (* task flag bits                *)
  194.     sigBit *   : SHORTINT;             (* signal bit                    *)
  195.  
  196.     clientID * : E.APTR;               (* the client's task ID          *)
  197.     msgPkt *   : E.APTR;               (* the packet being processed    *)
  198.     taskID *   : E.APTR;               (* our task ID                   *)
  199.     rexxPort * : E.APTR;               (* the REXX public port          *)
  200.  
  201.     errTrap *  : E.APTR;               (* Error trap address            *)
  202.     stackPtr * : E.APTR;               (* stack pointer for traps       *)
  203.  
  204.     header1 *  : E.List;               (* Environment list              *)
  205.     header2 *  : E.List;               (* Memory freelist               *)
  206.     header3 *  : E.List;               (* Memory allocation list        *)
  207.     header4 *  : E.List;               (* Files list                    *)
  208.     header5 *  : E.List;               (* Message Ports List            *)
  209.   END; (* RexxTask *)
  210.  
  211. CONST
  212.  
  213. (* Definitions for RexxTask flag bits                                   *)
  214.   rtfTrace   * = 0;                 (* external trace flag           *)
  215.   rtfHalt    * = 1;                 (* external halt flag            *)
  216.   rtfSusp    * = 2;                 (* suspend task?         *)
  217.   rtfTCUse   * = 3;                 (* trace console in use? *)
  218.   rtfWait    * = 6;                 (* waiting for reply?            *)
  219.   rtfClose   * = 7;                 (* task completed?               *)
  220.  
  221. (* Definitions for memory allocation constants                          *)
  222.   memQuant  * = 16;                  (* quantum of memory space       *)
  223.   memMask   * = 0FFFFFFF0H;           (* mask for rounding the size    *)
  224.  
  225.   memQuick  * = {0};           (* EXEC flags: public       *)
  226.   memClear  * = {16};          (* EXEC flags: memClear        *)
  227.  
  228. (* The SrcNode is a temporary structure used to hold values destined for
  229.  * a segment array.  It is also used to maintain the memory freelist.
  230.  *)
  231.  
  232. TYPE
  233.  
  234.   SrcNodePtr * = CPOINTER TO SrcNode;
  235.   SrcNode * = RECORD
  236.     succ * : SrcNodePtr;            (* next node                     *)
  237.     pred * : SrcNodePtr;            (* previous node                 *)
  238.     ptr *  : E.APTR;                (* pointer value                 *)
  239.     size * : LONGINT;               (* size of object                *)
  240.   END; (* SrcNode *)                (* size: 16 bytes                *)
  241.  
  242.  
  243. (*
  244. **      $VER: rexxio.h 1.4 (8.11.91)
  245. **
  246. **      Header file for ARexx Input/Output related structures
  247. *)
  248.  
  249.  
  250. CONST
  251.  
  252.   rxBuffSz  * = 204;                  (* buffer length         *)
  253.  
  254. (*
  255.  * The IoBuff is a resource node used to maintain the File List.  Nodes
  256.  * are allocated and linked into the list whenever a file is opened.
  257.  *)
  258.  
  259. TYPE
  260.  
  261.   IoBuffPtr * = CPOINTER TO IoBuff;
  262.   IoBuff * = RECORD (RexxRsrc)           (* structure for files/strings   *)
  263.     rpt *  : E.APTR;                     (* read/write pointer            *)
  264.     rct *  : LONGINT;                    (* character count               *)
  265.     dFH *  : D.FileHandlePtr;            (* DOS filehandle                *)
  266.     lock * : D.FileLockPtr;              (* DOS lock                      *)
  267.     bct *  : LONGINT;                    (* buffer length                 *)
  268.     area * : ARRAY rxBuffSz OF SYS.BYTE; (* buffer area                   *)
  269.   END; (* IoBuff *)                      (* size: 256 bytes               *)
  270.  
  271. CONST
  272.  
  273. (* Access mode definitions                                              *)
  274.   ioExist   * = -1;                (* an external filehandle        *)
  275.   ioStrF    * = 0;                 (* a "string file"               *)
  276.   ioRead    * = 1;                 (* read-only access              *)
  277.   ioWrite   * = 2;                 (* write mode                    *)
  278.   ioAppend  * = 3;                 (* append mode (existing file)   *)
  279.  
  280. (*
  281.  * Offset anchors for SeekF()
  282.  *)
  283.   ioBegin   * = -1;               (* relative to start             *)
  284.   ioCurr    * = 0;        (* relative to current position  *)
  285.   ioEnd     * = 1;        (* relative to end               *)
  286.  
  287. (* The Library List contains just plain resource nodes.         *)
  288.  
  289. (*
  290.  * The RexxClipNode structure is used to maintain the Clip List.  The value
  291.  * string is stored as an argstring in the rrArg1 field.
  292.  *)
  293.  
  294. (*
  295.  * A message port structure, maintained as a resource node.  The ReplyList
  296.  * holds packets that have been received but haven't been replied.
  297.  *)
  298.  
  299. TYPE
  300.  
  301.   RexxMsgPortPtr * = CPOINTER TO RexxMsgPort;
  302.   RexxMsgPort * = RECORD (RexxRsrc)   (* linkage node                  *)
  303.     port *      : E.MsgPort;          (* the message port              *)
  304.     replyList * : E.List;             (* messages awaiting reply       *)
  305.   END; (* RexxMsgPort *)
  306.  
  307. CONST
  308.  
  309. (*
  310.  * DOS Device types
  311.  *)
  312.  
  313.   dtDev    * = 0;                   (* a device                      *)
  314.   dtDir    * = 1;                   (* an ASSIGNed directory *)
  315.   dtVol    * = 2;                   (* a volume                      *)
  316.  
  317. (*
  318.  * Private DOS packet types
  319.  *)
  320.  
  321.   actionStack * = 2002;             (* stack a line                  *)
  322.   actionQueue * = 2003;             (* queue a line                  *)
  323.  
  324.  
  325. (*
  326. **      $VER: errors.h 1.4 (8.11.91)
  327. **
  328. **      Definitions for ARexx error codes
  329. *)
  330.  
  331. CONST
  332.  
  333.   errcMsg  * = 0;                 (*  error code offset           *)
  334.   err10001 * = errcMsg+1;         (*  program not found           *)
  335.   err10002 * = errcMsg+2;         (*  execution halted            *)
  336.   err10003 * = errcMsg+3;         (*  no memory available         *)
  337.   err10004 * = errcMsg+4;         (*  invalid character in program*)
  338.   err10005 * = errcMsg+5;         (*  unmatched quote             *)
  339.   err10006 * = errcMsg+6;         (*  unterminated comment        *)
  340.   err10007 * = errcMsg+7;         (*  clause too long             *)
  341.   err10008 * = errcMsg+8;         (*  unrecognized token          *)
  342.   err10009 * = errcMsg+9;         (*  symbol or string too long   *)
  343.  
  344.   err10010 * = errcMsg+10;        (*  invalid message packet      *)
  345.   err10011 * = errcMsg+11;        (*  command string error        *)
  346.   err10012 * = errcMsg+12;        (*  error return from function  *)
  347.   err10013 * = errcMsg+13;        (*  host environment not found  *)
  348.   err10014 * = errcMsg+14;        (*  required library not found  *)
  349.   err10015 * = errcMsg+15;        (*  function not found          *)
  350.   err10016 * = errcMsg+16;        (*  no return value             *)
  351.   err10017 * = errcMsg+17;        (*  wrong number of arguments   *)
  352.   err10018 * = errcMsg+18;        (*  invalid argument to function*)
  353.   err10019 * = errcMsg+19;        (*  invalid PROCEDURE           *)
  354.  
  355.   err10020 * = errcMsg+20;        (*  unexpected THEN/ELSE        *)
  356.   err10021 * = errcMsg+21;        (*  unexpected WHEN/OTHERWISE   *)
  357.   err10022 * = errcMsg+22;        (*  unexpected LEAVE or ITERATE *)
  358.   err10023 * = errcMsg+23;        (*  invalid statement in SELECT *)
  359.   err10024 * = errcMsg+24;        (*  missing THEN clauses        *)
  360.   err10025 * = errcMsg+25;        (*  missing OTHERWISE           *)
  361.   err10026 * = errcMsg+26;        (*  missing or unexpected END   *)
  362.   err10027 * = errcMsg+27;        (*  symbol mismatch on END      *)
  363.   err10028 * = errcMsg+28;        (*  invalid DO syntax           *)
  364.   err10029 * = errcMsg+29;        (*  incomplete DO/IF/SELECT     *)
  365.  
  366.   err10030 * = errcMsg+30;        (*  label not found             *)
  367.   err10031 * = errcMsg+31;        (*  symbol expected             *)
  368.   err10032 * = errcMsg+32;        (*  string or symbol expected   *)
  369.   err10033 * = errcMsg+33;        (*  invalid sub-keyword         *)
  370.   err10034 * = errcMsg+34;        (*  required keyword missing    *)
  371.   err10035 * = errcMsg+35;        (*  extraneous characters       *)
  372.   err10036 * = errcMsg+36;        (*  sub-keyword conflict        *)
  373.   err10037 * = errcMsg+37;        (*  invalid template            *)
  374.   err10038 * = errcMsg+38;        (*  invalid TRACE request       *)
  375.   err10039 * = errcMsg+39;        (*  uninitialized variable      *)
  376.  
  377.   err10040 * = errcMsg+40;        (*  invalid variable name       *)
  378.   err10041 * = errcMsg+41;        (*  invalid expression          *)
  379.   err10042 * = errcMsg+42;        (*  unbalanced parentheses      *)
  380.   err10043 * = errcMsg+43;        (*  nesting level exceeded      *)
  381.   err10044 * = errcMsg+44;        (*  invalid expression result   *)
  382.   err10045 * = errcMsg+45;        (*  expression required         *)
  383.   err10046 * = errcMsg+46;        (*  boolean value not 0 or 1    *)
  384.   err10047 * = errcMsg+47;        (*  arithmetic conversion error *)
  385.   err10048 * = errcMsg+48;        (*  invalid operand             *)
  386.  
  387. (*
  388.  * Return Codes for general use
  389.  *)
  390.   rcOk     * = 0;                   (*  success                     *)
  391.   rcWarn   * = 5;                   (*  warning only        *)
  392.   rcError  * = 10;                  (*  something's wrong           *)
  393.   rcFatal  * = 20;                  (*  complete or severe failure  *)
  394.  
  395.  
  396. (*
  397. **      $VER: rxslib.h 1.6 (8.11.91)
  398. **
  399. **      The header file for the REXX Systems Library
  400. *)
  401.  
  402.  
  403. CONST
  404.  
  405.   name  * = "rexxsyslib.library";
  406.   dir   * = "REXX";
  407.   tName * = "ARexx";
  408.  
  409. (* The REXX systems library structure.  This should be considered as    *)
  410. (* semi-private and read-only, except for documented exceptions.        *)
  411.  
  412. TYPE
  413.  
  414.   RxsLibPtr * = CPOINTER TO RxsLib;
  415.   RxsLib * = RECORD (E.Library)      (* EXEC library node             *)
  416.     rlFlags *    : E.BSET;           (* global flags                  *)
  417.     shadow *     : E.BSET;           (* shadow flags                  *)
  418.     sysBase *    : E.LibraryPtr;     (* EXEC library base             *)
  419.     dosBase *    : D.DosLibraryPtr;  (* DOS library base              *)
  420.     ieeeDPBase * : E.LibraryPtr;     (* IEEE DP math library base     *)
  421.     segList *    : SYS.BPTR;         (* library seglist               *)
  422.     nil *        : D.FileHandlePtr;  (* global NIL: filehandle        *)
  423.     chunk *      : LONGINT;          (* allocation quantum            *)
  424.     maxNest *    : LONGINT;          (* maximum expression nesting    *)
  425.     null *       : NexxStrPtr;       (* static string: NULL           *)
  426.     false *      : NexxStrPtr;       (* static string: FALSE          *)
  427.     true *       : NexxStrPtr;       (* static string: TRUE           *)
  428.     rexx *       : NexxStrPtr;       (* static string: REXX           *)
  429.     command *    : NexxStrPtr;       (* static string: COMMAND        *)
  430.     stdin *      : NexxStrPtr;       (* static string: STDIN          *)
  431.     stdout *     : NexxStrPtr;       (* static string: STDOUT         *)
  432.     stderr *     : NexxStrPtr;       (* static string: STDERR         *)
  433.     rlVersion *  : E.STRPTR;         (* version string                *)
  434.  
  435.     taskName *   : E.STRPTR;         (* name string for tasks *)
  436.     taskPri *    : LONGINT;          (* starting priority             *)
  437.     taskSeg *    : SYS.BPTR;         (* startup seglist               *)
  438.     stackSize *  : LONGINT;          (* stack size                    *)
  439.     rexxDir *    : E.STRPTR;         (* REXX directory                *)
  440.     cTable *     : E.STRPTR;         (* character attribute table     *)
  441.     notice *     : E.STRPTR;         (* copyright notice              *)
  442.  
  443.     rexxPort *   : E.MsgPort;        (* REXX public port              *)
  444.     readLock *   : E.UWORD;          (* lock count                    *)
  445.     traceFH *    : D.FileHandlePtr;  (* global trace console          *)
  446.     taskList *   : E.List;           (* REXX task list                *)
  447.     numTask *    : INTEGER;          (* task count                    *)
  448.     libList *    : E.List;           (* Library List header           *)
  449.     numLib *     : INTEGER;          (* library count                 *)
  450.     clipList *   : E.List;           (* ClipList header               *)
  451.     numClip *    : INTEGER;          (* clip node count               *)
  452.     msgList *    : E.List;           (* pending messages              *)
  453.     numMsg *     : INTEGER;          (* pending count                 *)
  454.     pgmList *    : E.List;           (* cached programs               *)
  455.     numPgm *     : INTEGER;          (* program count                 *)
  456.  
  457.     traceCnt *   : E.UWORD;          (* usage count for trace console *)
  458.     avail *      : INTEGER;
  459.   END; (* RxsLib *)
  460.  
  461. CONST
  462.  
  463. (* Global flag bit definitions for RexxMaster                           *)
  464.   rlfTrace * = rtfTrace;        (* interactive tracing?          *)
  465.   rlfHalt  * = rtfHalt;         (* halt execution?               *)
  466.   rlfSusp  * = rtfSusp;         (* suspend execution?            *)
  467.   rlfStop  * = 6;               (* deny further invocations      *)
  468.   rlfClose * = 7;               (* close the master              *)
  469.  
  470.   rlfMask    * = { rlfTrace, rlfHalt, rlfSusp };
  471.  
  472. (* Initialization constants                                             *)
  473.   chunk   * = 1024;        (* allocation quantum            *)
  474.   nest    * = 32;          (* expression nesting limit      *)
  475.   tPri    * = 0;           (* task priority         *)
  476.   stack   * = 4096;        (* stack size                    *)
  477.  
  478. (* Character attribute flag bits used in REXX.                          *)
  479.   ctSpace   * = 0;                  (* white space characters        *)
  480.   ctDigit   * = 1;                  (* decimal digits 0-9            *)
  481.   ctAlpha   * = 2;                  (* alphabetic characters *)
  482.   ctRexxSym * = 3;                  (* REXX symbol characters        *)
  483.   ctRexxOpr * = 4;                  (* REXX operator characters      *)
  484.   ctRexxSpc * = 5;                  (* REXX special symbols          *)
  485.   ctUpper   * = 6;                  (* UPPERCASE alphabetic          *)
  486.   ctLower   * = 7;                  (* lowercase alphabetic          *)
  487.  
  488. END Rexx.
  489.